xpgs [options] <polyh or xss file>
SIRDS stands for Single-Image Random Dots Stereogram; other common terms are RDS, SIS and autostereograms though these do not strictly apply to, or imply, SIRDS.
The theory of SIRDS and autostereograms can be found in many postings to alt.3d (including a FAQ obtainable from http://www.cs.waikato.ac.nz/~singlis/sirds.html) and comp.graphics, there are also some books around which deal with the subject. Some information can be obtained on RDS from Bela Julesz's book "Foundations of Cyclopean Perceptions"; a more recent source of information is the paper by Thimbleby et al called "Displaying 3D images: Algorithms for SIRDS", available from Stuart Inglis (singlis@waikato.ac.nz); also there is a short article called "Stereography and Autostereograms" by the author of this package which can be found, along with a gallery and URL links to other WWW pages on SIRDS, at http://h2.ph.man.ac.uk/gareth/sirds.html. Further resources can be found at the main SIRDS at ftp://katz.anu.edu.au/pub/stereograms/.
In this suite of programs, we start with a description of a volume of space using Cartesian coordinates to label the vertices of the objects within the space and lists of the polygonal faces which define each object. The coordinate axes are defined as x - horizontal (right), y - vertical (upward) and z - perpendicular to the screen (toward the viewer).
With this description, two buffers are built using a method described in the article mentioned above.
There are two basic types of autostereograms, these differ in the way the image is viewed. The two possibilities are wide-eyed (WE) and cross-eyed (CE) viewing. For whatever reasons, some people find it much easier to look at SIRDS cross-eyed though the vast majority learn to see them wide-eyed.
The parameters of the programs are :-
The default options are set to give a reasonable wide-eyed (WE) SIRDS of the objects on top of a background plane.
A layout of the suite's programs and associated data follows
3d datasets
|
|
v
cvtopolyh mkpolyh
| |
| |
| |
/-------------------------\ paint package
| | | ^
| (.polyh) | (.polyh) | | (.p?m)
| | | |
v v v v
xss --------> xpgs -------> cvtoppm <------ mindimage
| (.xss) | | | (.rle)
| | (.p?m) | |
| | v |
\-------------------> sisgen \----------> vpgs
(.xss) | (.p?m)
|
|
v
xv
MindImage is a PC SIRDS generator, xv is the X11 graphics viewer. The data files are differentiated by their name extensions given in parentheses. Although not shown on the diagram, xss, vpgs and xpgs can save an image in X11 bitmap (.xbm) format and vpgs and xpgs can also save an image as a Postscript (.ps) file.
Additional objects can be converted into this format using the cvtopolyh program, it is able to change X3d v2.0 .obj files, Wavefront .obj files and another format .3ds (I can't remember what program uses this). New objects defined by functions can be made using mkpolyh.
We have bundled some objects for you to try out - regular solids in polyh format and a couple of objects converted from X3d v2.0 objects and Wavefront objects.
More objects can be found at ftp://avalon.vislab.navy.mil/ or its mirrors.
If xpgs was compiled with the XPGSUSEPM macro defined then the number of frames of animation possible depends on the X server memory allocation, ie. the number of big Pixmaps it can support. If your server can't handle a large number then either give xpgs a smaller number of frames, eg. "-f 3", or recompile xpgs without the -DXPGSUSEPM flag in the Makefile (make.com or descrip.mms). Note if you take the latter option then the animation may not be as fast as using Pixmaps, the performance depends on the X server.
This limits the internal size of all z-buffers used in the program without affecting the size of the stereogram output. It should be used only when memory constraints are more important than speed considerations: the smaller the value is the slower the program will become.
Once running, it will display a few parameters in the terminal window, create a empty graphics window and start to generate the SIRDS(s). Each frame will be shown in sequence as the program proceeds. When finished, the program displays the "all done" message and enters the pause mode.
With the mouse pointer within the boundaries of the graphics window, xpgs will respond to a set of keypresses.
While paused:
See xss(6) about mouse controls and popup dialogue windows.
If you find any bugs, please report them to one of the authors listed below.
cvtopolyh(6), cvtoppm(6), mkpolyh(6), sisgen(6), vpgs(6), xpgs(6) and xss(6).
Copyright 1994 and 1995, 26th January.
By Peter Chang and Gareth Richards. All rights reserved.
Version 2.5
Permission to use, copy, modify, distribute, and sell this software and its documentation for any purpose is hereby granted without fee, provided that the above copyright notice appear in all copies and that both that copyright notice and this permission notice appear in supporting documentation, and that the name of the copyright holder not be used in advertising or publicity pertaining to distribution of the software without specific, written prior permission. The copyright holder makes no representations about the suitability of this software for any purpose. It is provided "as is" without express or implied warranty.
The copyright holder disclaims all warranties with regard to this software, including all implied warranties of merchantability and fitness, in no event shall the copyright holder be liable for any special, indirect or consequential damages or any damages whatsoever resulting from loss of use, data or profits, whether in an action of contract, negligence or other tortious action, arising out of or in connection with the use or performance of this software.